package com.feihong.yw189.model.Spec;

import android.os.Parcel;
import android.os.Parcelable;

import java.util.List;

/**
 * @Author wangziheng
 * @ProjectName ywydt
 * @ClassName SpecInfoModel
 * @package com.feihong.yw189.model
 * @data 2018/10/11 17:11
 * @Describe
 * @Change
 */
public class SpecInfoModel {


    public SpecInfoModel() {
    }

    /**
     * status : 1
     * info : 套餐获取成功！
     * data : [{"spec_g_id":"3345","spec_g_name":"宽带4G测试组","info":"测试专用组","spec_type":"34","spec_list":[{"spec_id":"18546","spec_g_id":"3345","spec_name":"单固话","spec_info":"单固话","price":"0.00","dp_price":"0.00","system_spec_id":"1804","is_show":"1","user_group_id":"8239","show_parms":{"is_dizhi":1,"is_tel":1,"is_phone":{"min":1,"max":2},"is_input":[{"name":"主号码","value":"mobile"},{"name":"机主姓名","value":"name"}],"is_sulv":["100","200","500"],"is_hongbao":[]},"region_id":"457"},{"spec_id":"17597","spec_g_id":"3345","spec_name":"宽带测试","spec_info":"宽带测试","price":"0.00","dp_price":"0.00","system_spec_id":"1652","is_show":"1","user_group_id":"8239","show_parms":{"is_dizhi":1,"is_tel":1,"is_phone":{"min":1,"max":2},"is_input":[{"name":"主号码","value":"mobile"},{"name":"机主姓名","value":"name"}],"is_sulv":["100","200","500"],"is_hongbao":[]},"region_id":"457"}],"spec_type_name":"电信4G宽带套餐"}]
     */


    private int status;
    private String info;
    private List<DataBean> data;

    public int getStatus() {
        return status;
    }

    public void setStatus(int status) {
        this.status = status;
    }

    public String getInfo() {
        return info;
    }

    public void setInfo(String info) {
        this.info = info;
    }

    public List<DataBean> getData() {
        return data;
    }

    public void setData(List<DataBean> data) {
        this.data = data;
    }

    public static class DataBean implements Parcelable{
        /**
         * spec_g_id : 3345
         * spec_g_name : 宽带4G测试组
         * info : 测试专用组
         * spec_type : 34
         * spec_list : [{"spec_id":"18546","spec_g_id":"3345","spec_name":"单固话","spec_info":"单固话","price":"0.00","dp_price":"0.00","system_spec_id":"1804","is_show":"1","user_group_id":"8239","show_parms":{"is_dizhi":1,"is_tel":1,"is_phone":{"min":1,"max":2},"is_input":[{"name":"主号码","value":"mobile"},{"name":"机主姓名","value":"name"}],"is_sulv":["100","200","500"],"is_hongbao":[]},"region_id":"457"},{"spec_id":"17597","spec_g_id":"3345","spec_name":"宽带测试","spec_info":"宽带测试","price":"0.00","dp_price":"0.00","system_spec_id":"1652","is_show":"1","user_group_id":"8239","show_parms":{"is_dizhi":1,"is_tel":1,"is_phone":{"min":1,"max":2},"is_input":[{"name":"主号码","value":"mobile"},{"name":"机主姓名","value":"name"}],"is_sulv":["100","200","500"],"is_hongbao":[]},"region_id":"457"}]
         * spec_type_name : 电信4G宽带套餐
         */

        private String spec_g_id;
        private String spec_g_name;
        private String info;
        private String spec_type;
        private String spec_type_name;
        private List<SpecListBean> spec_list;

        public DataBean() {
        }

        public DataBean(String spec_g_id, String spec_g_name, String info, String spec_type, String spec_type_name, List<SpecListBean> spec_list) {
            this.spec_g_id = spec_g_id;
            this.spec_g_name = spec_g_name;
            this.info = info;
            this.spec_type = spec_type;
            this.spec_type_name = spec_type_name;
            this.spec_list = spec_list;
        }

        protected DataBean(Parcel in) {
            spec_g_id = in.readString();
            spec_g_name = in.readString();
            info = in.readString();
            spec_type = in.readString();
            spec_type_name = in.readString();
            spec_list = in.createTypedArrayList(SpecListBean.CREATOR);
        }

        public static final Creator<DataBean> CREATOR = new Creator<DataBean>() {
            @Override
            public DataBean createFromParcel(Parcel in) {
                return new DataBean(in);
            }

            @Override
            public DataBean[] newArray(int size) {
                return new DataBean[size];
            }
        };

        public String getSpec_g_id() {
            return spec_g_id;
        }

        public void setSpec_g_id(String spec_g_id) {
            this.spec_g_id = spec_g_id;
        }

        public String getSpec_g_name() {
            return spec_g_name;
        }

        public void setSpec_g_name(String spec_g_name) {
            this.spec_g_name = spec_g_name;
        }

        public String getInfo() {
            return info;
        }

        public void setInfo(String info) {
            this.info = info;
        }

        public String getSpec_type() {
            return spec_type;
        }

        public void setSpec_type(String spec_type) {
            this.spec_type = spec_type;
        }

        public String getSpec_type_name() {
            return spec_type_name;
        }

        public void setSpec_type_name(String spec_type_name) {
            this.spec_type_name = spec_type_name;
        }

        public List<SpecListBean> getSpec_list() {
            return spec_list;
        }

        public void setSpec_list(List<SpecListBean> spec_list) {
            this.spec_list = spec_list;
        }

        @Override
        public int describeContents() {
            return 0;
        }

        @Override
        public void writeToParcel(Parcel dest, int flags) {
            dest.writeString(spec_g_id);
            dest.writeString(spec_g_name);
            dest.writeString(info);
            dest.writeString(spec_type);
            dest.writeString(spec_type_name);
            dest.writeTypedList(spec_list);
        }

        public static class SpecListBean implements Parcelable{

            public SpecListBean() {
            }

            public SpecListBean(String spec_id, String spec_name, String spec_info, String price, String dp_price, String system_spec_id, String is_show, String user_group_id, ShowParmsBean show_parms, String region_id, String specGroupID, String specGroupTypeName) {
                this.spec_id = spec_id;
                this.spec_name = spec_name;
                this.spec_info = spec_info;
                this.price = price;
                this.dp_price = dp_price;
                this.system_spec_id = system_spec_id;
                this.is_show = is_show;
                this.user_group_id = user_group_id;
                this.show_parms = show_parms;
                this.region_id = region_id;
                this.specGroupID = specGroupID;
                this.specGroupTypeName = specGroupTypeName;
            }

            /**
             * spec_id : 18546
             * spec_g_id : 3345
             * spec_name : 单固话
             * spec_info : 单固话
             * price : 0.00
             * dp_price : 0.00
             * system_spec_id : 1804
             * is_show : 1
             * user_group_id : 8239
             * show_parms : {"is_dizhi":1,"is_tel":1,"is_phone":{"min":1,"max":2},"is_input":[{"name":"主号码","value":"mobile"},{"name":"机主姓名","value":"name"}],"is_sulv":["100","200","500"],"is_hongbao":[]}
             * region_id : 457
             *
             * specGroupID 套餐组ID
             * specGroupTypeName 套餐组类型名称
             */


            private String spec_id;
            private String spec_g_id;
            private String spec_name;
            private String spec_info;
            private String price;
            private String dp_price;
            private String system_spec_id;
            private String is_show;
            private String user_group_id;
            private ShowParmsBean show_parms;
            private String region_id;
            private String specGroupID;
            private String specGroupTypeName;

            protected SpecListBean(Parcel in) {
                spec_id = in.readString();
                spec_g_id = in.readString();
                spec_name = in.readString();
                spec_info = in.readString();
                price = in.readString();
                dp_price = in.readString();
                system_spec_id = in.readString();
                is_show = in.readString();
                user_group_id = in.readString();
                show_parms = in.readParcelable(ShowParmsBean.class.getClassLoader());
                region_id = in.readString();
                specGroupID = in.readString();
                specGroupTypeName = in.readString();
            }

            public static final Creator<SpecListBean> CREATOR = new Creator<SpecListBean>() {
                @Override
                public SpecListBean createFromParcel(Parcel in) {
                    return new SpecListBean(in);
                }

                @Override
                public SpecListBean[] newArray(int size) {
                    return new SpecListBean[size];
                }
            };

            public String getSpec_g_id() {
                return spec_g_id;
            }

            public void setSpec_g_id(String spec_g_id) {
                this.spec_g_id = spec_g_id;
            }

            public String getSpecGroupID() {
                return specGroupID;
            }

            public void setSpecGroupID(String specGroupID) {
                this.specGroupID = specGroupID;
            }

            public String getSpecGroupTypeName() {
                return specGroupTypeName;
            }

            public void setSpecGroupTypeName(String specGroupTypeName) {
                this.specGroupTypeName = specGroupTypeName;
            }

            public String getSpec_id() {
                return spec_id;
            }

            public void setSpec_id(String spec_id) {
                this.spec_id = spec_id;
            }


            public String getSpec_name() {
                return spec_name;
            }

            public void setSpec_name(String spec_name) {
                this.spec_name = spec_name;
            }

            public String getSpec_info() {
                return spec_info;
            }

            public void setSpec_info(String spec_info) {
                this.spec_info = spec_info;
            }

            public String getPrice() {
                return price;
            }

            public void setPrice(String price) {
                this.price = price;
            }

            public String getDp_price() {
                return dp_price;
            }

            public void setDp_price(String dp_price) {
                this.dp_price = dp_price;
            }

            public String getSystem_spec_id() {
                return system_spec_id;
            }

            public void setSystem_spec_id(String system_spec_id) {
                this.system_spec_id = system_spec_id;
            }

            public String getIs_show() {
                return is_show;
            }

            public void setIs_show(String is_show) {
                this.is_show = is_show;
            }

            public String getUser_group_id() {
                return user_group_id;
            }

            public void setUser_group_id(String user_group_id) {
                this.user_group_id = user_group_id;
            }

            public ShowParmsBean getShow_parms() {
                return show_parms;
            }

            public void setShow_parms(ShowParmsBean show_parms) {
                this.show_parms = show_parms;
            }

            public String getRegion_id() {
                return region_id;
            }

            public void setRegion_id(String region_id) {
                this.region_id = region_id;
            }

            @Override
            public int describeContents() {
                return 0;
            }

            @Override
            public void writeToParcel(Parcel dest, int flags) {
                dest.writeString(spec_id);
                dest.writeString(spec_g_id);
                dest.writeString(spec_name);
                dest.writeString(spec_info);
                dest.writeString(price);
                dest.writeString(dp_price);
                dest.writeString(system_spec_id);
                dest.writeString(is_show);
                dest.writeString(user_group_id);
                dest.writeParcelable(show_parms, flags);
                dest.writeString(region_id);
                dest.writeString(specGroupID);
                dest.writeString(specGroupTypeName);
            }

            public static class ShowParmsBean implements Parcelable {
                /**
                 * is_dizhi : 1
                 * is_tel : 1
                 * is_phone : {"min":1,"max":2}
                 * is_input : [{"name":"主号码","value":"mobile"},{"name":"机主姓名","value":"name"}]
                 * is_sulv : ["100","200","500"]
                 * is_hongbao : []
                 */

                private int is_dizhi;
                private int is_tel;
                private IsPhoneBean is_phone;
                private List<IsInputBean> is_input;
                private List<String> is_sulv;
                private List<?> is_hongbao;

                public ShowParmsBean() {
                }

                public ShowParmsBean(int is_dizhi, int is_tel, IsPhoneBean is_phone, List<IsInputBean> is_input, List<String> is_sulv, List<?> is_hongbao) {
                    this.is_dizhi = is_dizhi;
                    this.is_tel = is_tel;
                    this.is_phone = is_phone;
                    this.is_input = is_input;
                    this.is_sulv = is_sulv;
                    this.is_hongbao = is_hongbao;
                }


                protected ShowParmsBean(Parcel in) {
                    is_dizhi = in.readInt();
                    is_tel = in.readInt();
                    is_phone = in.readParcelable(IsPhoneBean.class.getClassLoader());
                    is_input = in.createTypedArrayList(IsInputBean.CREATOR);
                    is_sulv = in.createStringArrayList();
                }

                public static final Creator<ShowParmsBean> CREATOR = new Creator<ShowParmsBean>() {
                    @Override
                    public ShowParmsBean createFromParcel(Parcel in) {
                        return new ShowParmsBean(in);
                    }

                    @Override
                    public ShowParmsBean[] newArray(int size) {
                        return new ShowParmsBean[size];
                    }
                };

                public int getIs_dizhi() {
                    return is_dizhi;
                }

                public void setIs_dizhi(int is_dizhi) {
                    this.is_dizhi = is_dizhi;
                }

                public int getIs_tel() {
                    return is_tel;
                }

                public void setIs_tel(int is_tel) {
                    this.is_tel = is_tel;
                }

                public IsPhoneBean getIs_phone() {
                    return is_phone;
                }

                public void setIs_phone(IsPhoneBean is_phone) {
                    this.is_phone = is_phone;
                }

                public List<IsInputBean> getIs_input() {
                    return is_input;
                }

                public void setIs_input(List<IsInputBean> is_input) {
                    this.is_input = is_input;
                }

                public List<String> getIs_sulv() {
                    return is_sulv;
                }

                public void setIs_sulv(List<String> is_sulv) {
                    this.is_sulv = is_sulv;
                }

                public List<?> getIs_hongbao() {
                    return is_hongbao;
                }

                public void setIs_hongbao(List<?> is_hongbao) {
                    this.is_hongbao = is_hongbao;
                }

                @Override
                public int describeContents() {
                    return 0;
                }

                @Override
                public void writeToParcel(Parcel dest, int flags) {
                    dest.writeInt(is_dizhi);
                    dest.writeInt(is_tel);
                    dest.writeParcelable(is_phone, flags);
                    dest.writeTypedList(is_input);
                    dest.writeStringList(is_sulv);
                }


                public static class IsPhoneBean implements Parcelable{
                    /**
                     * min : 1
                     * max : 2
                     */

                    private int min;
                    private int max;

                    public IsPhoneBean() {
                    }

                    public IsPhoneBean(int min, int max) {
                        this.min = min;
                        this.max = max;
                    }

                    protected IsPhoneBean(Parcel in) {
                        min = in.readInt();
                        max = in.readInt();
                    }

                    public static final Creator<IsPhoneBean> CREATOR = new Creator<IsPhoneBean>() {
                        @Override
                        public IsPhoneBean createFromParcel(Parcel in) {
                            return new IsPhoneBean(in);
                        }

                        @Override
                        public IsPhoneBean[] newArray(int size) {
                            return new IsPhoneBean[size];
                        }
                    };

                    public int getMin() {
                        return min;
                    }

                    public void setMin(int min) {
                        this.min = min;
                    }

                    public int getMax() {
                        return max;
                    }

                    public void setMax(int max) {
                        this.max = max;
                    }

                    @Override
                    public int describeContents() {
                        return 0;
                    }

                    @Override
                    public void writeToParcel(Parcel dest, int flags) {
                        dest.writeInt(min);
                        dest.writeInt(max);
                    }
                }

                public static class IsInputBean implements Parcelable{
                    /**
                     * name : 主号码
                     * value : mobile
                     */

                    private String name;
                    private String value;
                    private String type;
                    public IsInputBean() {
                    }

                    public IsInputBean(String name, String value, String type) {
                        this.name = name;
                        this.value = value;
                        this.type = type;
                    }

                    protected IsInputBean(Parcel in) {
                        name = in.readString();
                        value = in.readString();
                        type = in.readString();
                    }

                    public static final Creator<IsInputBean> CREATOR = new Creator<IsInputBean>() {
                        @Override
                        public IsInputBean createFromParcel(Parcel in) {
                            return new IsInputBean(in);
                        }

                        @Override
                        public IsInputBean[] newArray(int size) {
                            return new IsInputBean[size];
                        }
                    };

                    public String getName() {
                        return name;
                    }

                    public void setName(String name) {
                        this.name = name;
                    }

                    public String getValue() {
                        return value;
                    }

                    public void setValue(String value) {
                        this.value = value;
                    }

                    public String getType() {
                        return type;
                    }

                    public void setType(String type) {
                        this.type = type;
                    }

                    @Override
                    public int describeContents() {
                        return 0;
                    }

                    @Override
                    public void writeToParcel(Parcel dest, int flags) {
                        dest.writeString(name);
                        dest.writeString(value);
                        dest.writeString(type);
                    }
                }
            }
        }
    }
}
